home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2009 February / PCWFEB09.iso / Software / Linux / SLAX 6.0.8 / slax-6.0.8.iso / slax / base / 006-devel.lzm / usr / include / idn-free.h < prev    next >
Encoding:
Text File  |  2008-02-26  |  1.7 KB  |  41 lines

  1. /* idn-free.h --- Invoke the `free' function releasing memory
  2.  *                allocated by libidn functions.
  3.  * Copyright (C) 2004, 2005, 2006, 2007 Simon Josefsson
  4.  *
  5.  * This file is part of GNU Libidn.
  6.  *
  7.  * GNU Libidn is free software; you can redistribute it and/or
  8.  * modify it under the terms of the GNU Lesser General Public
  9.  * License as published by the Free Software Foundation; either
  10.  * version 2.1 of the License, or (at your option) any later version.
  11.  *
  12.  * GNU Libidn is distributed in the hope that it will be useful,
  13.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  14.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  15.  * Lesser General Public License for more details.
  16.  *
  17.  * You should have received a copy of the GNU Lesser General Public
  18.  * License along with GNU Libidn; if not, write to the Free Software
  19.  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
  20.  *
  21.  */
  22.  
  23. /* I don't recommend using this interface in general.  Use `free'.
  24.  *
  25.  * I'm told Microsoft Windows may use one set of `malloc' and `free'
  26.  * in a library, and another incompatible set in a statically compiled
  27.  * application that link to the library, thus creating problems if the
  28.  * application would invoke `free' on a pointer pointing to memory
  29.  * allocated by the library.  This motivated adding this function.
  30.  *
  31.  * The theory of isolating all memory allocations and de-allocations
  32.  * within a code package (library) sounds good, to simplify hunting
  33.  * down memory allocation related problems, but I'm not sure if it is
  34.  * worth enough to motivate recommending this interface over calling
  35.  * `free' directly, though.
  36.  *
  37.  * If you have any thoughts or comments on this, please let me know.
  38.  */
  39.  
  40. void idn_free (void *ptr);
  41.